package com.jarvis.hospital.prescription.adapter;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.jarvis.hospital.R;
import com.jarvis.hospital.patient.model.TaskModel;
import com.jarvis.hospital.prescription.model.MedicineStockModel;

import java.util.List;

/**
 * Created by jarvis.liu on 9/12/2016.
 */
public class MedicineStockAdapter extends BaseQuickAdapter<MedicineStockModel> {
    public MedicineStockAdapter(int layoutResId, List<MedicineStockModel> data) {
        super(layoutResId, data);
    }

    @Override
    protected void convert(BaseViewHolder baseViewHolder, MedicineStockModel medicineStockModel) {
        baseViewHolder
                .setText(R.id.tv_medicine_name, "药品名称："+medicineStockModel.getMedicineName())
                .setText(R.id.tv_operator_name, "操作者："+medicineStockModel.getUserName())
                .setText(R.id.tv_type, "出入类别："+medicineStockModel.getInOutType())
                .setText(R.id.tv_dose, "出入数量："+medicineStockModel.getMedicineDose())
                .setText(R.id.tv_stock, "药品库存："+medicineStockModel.getMedicineStock())
                .setText(R.id.tv_time, "出入时间："+medicineStockModel.getInOutTime());
    }
}
